
package org.apache.solr.core;

import java.io.File;
import java.io.IOException;
import org.apache.lucene.store.Directory;
import org.apache.lucene.store.FSDirectory;
import org.apache.lucene.store.NRTCachingDirectory;

/**
 * Factory to instantiate {@link org.apache.lucene.store.NRTCachingDirectory}
 */
public class NRTCachingDirectoryFactory extends StandardDirectoryFactory {

    @Override
    protected Directory create(String path) throws IOException {
        return new NRTCachingDirectory(FSDirectory.open(new File(path)), 4, 48);
    }
}
